package org.codeart.common.dto;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.time.LocalDateTime;

@TableName(value = "tb_order_info")
@Data
@NoArgsConstructor
@AllArgsConstructor
@Accessors(chain = true)
public class OrderInfo implements Serializable {

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;

    /**
     * 订单ID
     */
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    /**
     * 乘客ID
     */
    @TableField(value = "passenger_id")
    private Long passengerId;

    /**
     * 乘客手机号
     */
    @TableField(value = "passenger_phone")
    private String passengerPhone;

    /**
     * 司机ID
     */
    @TableField(value = "driver_id")
    private Long driverId;

    /**
     * 司机手机号
     */
    @TableField(value = "driver_phone")
    private String driverPhone;

    /**
     * 车辆Id
     */
    @TableField(value = "car_id")
    private Long carId;

    /**
     *
     */
    @TableField(value = "vehicle_type")
    private String vehicleType;

    /**
     * 发起地行政区划代码
     */
    @TableField(value = "address")
    private String address;

    /**
     * 订单发起时间
     */
    @TableField(value = "order_time")
    private LocalDateTime orderTime;

    /**
     * 预计用车时间
     */
    @TableField(value = "depart_time")
    private LocalDateTime departTime;

    /**
     * 预计出发地点详细地址
     */
    @TableField(value = "departure")
    private String departure;

    /**
     * 预计出发地点经度
     */
    @TableField(value = "dep_longitude")
    private String depLongitude;

    /**
     * 预计出发地点纬度
     */
    @TableField(value = "dep_latitude")
    private String depLatitude;

    /**
     * 预计目的地
     */
    @TableField(value = "destination")
    private String destination;

    /**
     * 预计目的地经度
     */
    @TableField(value = "dest_longitude")
    private String destLongitude;

    /**
     * 预计目的地纬度
     */
    @TableField(value = "dest_latitude")
    private String destLatitude;

    /**
     * 坐标加密标识
     * 1:GCJ-02测绘局标准
     * 2:WGS84 GPS标准
     * 3:BD-09 百度标准
     * 4:CGCS2000 北斗标准
     * 0:其他
     */
    @TableField(value = "encrypt")
    private Integer encrypt;

    /**
     * 运价类型编码
     */
    @TableField(value = "fare_type")
    private String fareType;

    /**
     * 运价类型版本
     */
    @TableField(value = "fare_version")
    private Integer fareVersion;

    /**
     * 接单时车辆经度
     */
    @TableField(value = "receive_order_car_longitude")
    private String receiveOrderCarLongitude;

    /**
     * 接单时车辆纬度
     */
    @TableField(value = "receive_order_car_latitude")
    private String receiveOrderCarLatitude;

    /**
     * 接单时间，派单成功时间
     */
    @TableField(value = "receive_order_time")
    private LocalDateTime receiveOrderTime;

    /**
     * 机动车驾驶证号
     */
    @TableField(value = "license_id")
    private String licenseId;

    /**
     * 车辆号牌
     */
    @TableField(value = "vehicle_no")
    private String vehicleNo;

    /**
     * 司机去接乘客出发时间
     */
    @TableField(value = "to_pick_up_passenger_time")
    private LocalDateTime toPickUpPassengerTime;

    /**
     * 去接乘客时，司机的经度
     */
    @TableField(value = "to_pick_up_passenger_longitude")
    private String toPickUpPassengerLongitude;

    /**
     * 去接乘客时，司机的纬度
     */
    @TableField(value = "to_pick_up_passenger_latitude")
    private String toPickUpPassengerLatitude;

    /**
     * 去接乘客时，司机的地点
     */
    @TableField(value = "to_pick_up_passenger_address")
    private String toPickUpPassengerAddress;

    /**
     * 司机到达上车点时间
     */
    @TableField(value = "driver_arrived_departure_time")
    private LocalDateTime driverArrivedDepartureTime;

    /**
     * 接到乘客，乘客上车时间
     */
    @TableField(value = "pick_up_passenger_time")
    private LocalDateTime pickUpPassengerTime;

    /**
     * 接到乘客，乘客上车经度
     */
    @TableField(value = "pick_up_passenger_longitude")
    private String pickUpPassengerLongitude;

    /**
     * 接到乘客，乘客上车纬度
     */
    @TableField(value = "pick_up_passenger_latitude")
    private String pickUpPassengerLatitude;

    /**
     * 乘客下车时间
     */
    @TableField(value = "passenger_getoff_time")
    private LocalDateTime passengerGetoffTime;

    /**
     * 乘客下车经度
     */
    @TableField(value = "passenger_getoff_longitude")
    private String passengerGetoffLongitude;

    /**
     * 乘客下车纬度
     */
    @TableField(value = "passenger_getoff_latitude")
    private String passengerGetoffLatitude;

    /**
     * 订单撤销时间
     */
    @TableField(value = "cancel_time")
    private LocalDateTime cancelTime;

    /**
     * 撤销发起者：1:乘客
     * 2:驾驶员
     * 3:平台公司
     */
    @TableField(value = "cancel_operator")
    private Integer cancelOperator;

    /**
     * 撤销类型代码
     * 1:乘客提前撤销
     * 2:驾驶员提前撤销
     * 3:平台公司撤销
     * 4;乘客违约撤销
     * 5:驾驶员违约撤销
     */
    @TableField(value = "cancel_type_code")
    private Integer cancelTypeCode;

    /**
     * 载客里程（米）
     */
    @TableField(value = "drive_mile")
    private Long driveMile;

    /**
     * 载客时间(分)
     */
    @TableField(value = "drive_time")
    private Long driveTime;

    /**
     * 订单状态1：订单开始 2：司机接单 3：去接乘客 4：司机到达乘客起点 5：乘客上车，司机开始行程 6：到达目的地，行程结束，未支付 7：发起收款 8: 支付完成 9.订单取消'
     */
    @TableField(value = "order_status")
    private Integer orderStatus;

    /**
     *
     */
    @TableField(value = "price")
    private Double price;

    /**
     * 创建时间
     */
    @TableField(value = "gmt_create")
    private LocalDateTime gmtCreate;

    /**
     * 修改时间
     */
    @TableField(value = "gmt_modified")
    private LocalDateTime gmtModified;
}